
export const PARAMS_SUBPACKAGE = [
    {
        type: "input",
        field: "name",
        title: "劳务分包名称",
        value: "",
        props: {placeholder:"请输入劳务分包名称"}
    },
  /*   {
        type: "select",
        field: "name1",
        title: "劳务形式",
        value: "",
        options:[{label:'长期招募',value:1},{label:'临时用工',value:2}],
        props: {placeholder:"请选择劳务形式"}
    }, */
    {
      type:'el-button',
      field:'search',
      props:{
          type:'primary',
          icon:"el-icon-search"
      },
      children:['搜索'],
      emit: ['click'],
      emitPrefix: 'btn-search',
    },
    {
      type:'el-button',
      field:'reset',
      props:{
          type:'primary',
          icon:"el-icon-setting"
      },
      children:['重置'],
      emit: ['click'],
      emitPrefix: 'btn-reset',
    },
    {
      type:'el-button',
      field:'userAdd',
      props:{
          type:'danger',
          icon:"el-icon-plus",
          style:"display:block"
      },
      children:['新增'],
      emit: ['click'],
      emitPrefix: 'btn-add',
    }
  ]
  
  export let FORM_SUBPACKAGE = [
    {
      type: "input",
      field: "name",
      title: "劳务分包名称",
      value: "",
      props: { type: "text"},
      validate: [
        { required: true, message: "请输入专业劳务名称", trigger: "blur" }
      ]
    },
    {
      type: "input",
      field: "contactPhone",
      title: "联系电话",
      value: "",
      props: { type: "text",maxlength:11},
      validate: [
        { required: true, message: "请输入联系电话", trigger: "blur" },
        {
          validator: (rule, val, d) => {
            val && !/^1(3[0-9]|4[5,7]|5[0,1,2,3,5,6,7,8,9]|6[2,5,6,7]|7[0,1,7,8]|8[0-9]|9[1,8,9])\d{8}$/.test(val) ? d(true) : d();
          },
          message: "手机格式错误"
        }
      ]
    },
    {
      type: "input",
      field: "mainBusiness",
      title: "业务范围",
      value: "",
      props: { type: "textarea"},
      validate: [
        { required: true, message: "请输入业务范围", trigger: "blur" }
      ]
    }
  ]


export const LABEL_SUBPACKAGE = [
  { label: "创建时间", prop: "createTime",width:'150',type:"createTime" },
  { label: "劳务分包名称", prop: "name",width:'180',type:"normal"},
  { label: "业务范围", prop:'mainBusiness',width:'180',type:"normal"},
  { label: "联系电话", prop:'contactPhone',width:'100',type:"normal"},
  { label: "创建人", prop: "createUserName",width:'100',type:"normal"},
  { label: "更新时间", prop: "updateTime",width:'150',type:"updateTime" }
]


export const PARAMS_MAJOR_SUBPACKAGE = [
    {
        type: "input",
        field: "name",
        title: "专业分包名称",
        value: "",
        props: {placeholder:"请输入专业分包名称"}
    },
    {
      type:'el-button',
      field:'search',
      props:{
          type:'primary',
          icon:"el-icon-search"
      },
      children:['搜索'],
      emit: ['click'],
      emitPrefix: 'btn-search',
    },
    {
      type:'el-button',
      field:'reset',
      props:{
          type:'primary',
          icon:"el-icon-setting"
      },
      children:['重置'],
      emit: ['click'],
      emitPrefix: 'btn-reset',
    },
    {
      type:'el-button',
      field:'userAdd',
      props:{
          type:'danger',
          icon:"el-icon-plus",
          style:"display:block"
      },
      children:['新增'],
      emit: ['click'],
      emitPrefix: 'btn-add',
    }
  ]
  
  export let FORM_MAJOR_SUBPACKAGE = [
    {
      type: "input",
      field: "name",
      title: "专业分包名称",
      value: "",
      props: { type: "text"},
      validate: [
        { required: true, message: "请输入专业分包名称", trigger: "blur" }
      ]
    },
    {
      type: "input",
      field: "contactPhone",
      title: "联系电话",
      value: "",
      props: { type: "text",maxlength:11},
      validate: [
        { required: true, message: "请输入联系电话", trigger: "blur" },
        {
          validator: (rule, val, d) => {
            val && !/^1(3[0-9]|4[5,7]|5[0,1,2,3,5,6,7,8,9]|6[2,5,6,7]|7[0,1,7,8]|8[0-9]|9[1,8,9])\d{8}$/.test(val) ? d(true) : d();
          },
          message: "手机格式错误"
        }
      ]
    },
    {
      type: "input",
      field: "mainBusiness",
      title: "业务范围",
      value: "",
      props: { type: "textarea"},
      validate: [
        { required: true, message: "请输入业务范围", trigger: "blur" }
      ]
    }
  ]


export const LABEL_MAJOR_SUBPACKAGE = [
  { label: "创建时间", prop: "createTime",width:'150',type:"createTime"},
  { label: "专业分包名称", prop: "name",width:'180',type:"normal"},
  { label: "业务范围", prop:'mainBusiness',width:'180',type:"normal"},
  { label: "联系电话", prop:'contactPhone',width:'100',type:"normal"},
  { label: "创建人", prop: "createUserName",width:'100',type:"normal"},
  { label: "更新时间", prop: "updateTime",width:'150',type:"updateTime"}
]

  export const OPTION_INLINE = {
    form: { labelWidth: "" ,inline: true,size:"small"},
    resetBtn: false,
    submitBtn: false
  }
  export const OPTION_BLOCK= {
    form: { labelWidth: "" ,size:"small"},
    row:{gutter: 20},
    resetBtn: false,
    submitBtn: false
  }



